#!/bin/bash
source "$( dirname "${BASH_SOURCE[0]}" )/../common/cm_utils.sh"
source "$( dirname "${BASH_SOURCE[0]}" )/../common/fs_utils.sh"

if [ -z "${OECORE_TARGET_SYSROOT}" ]
then
    echo "OECORE_TARGET_SYSROOT not set"
    exit 1
fi

srcDir="${HOME}/work/apd-git/ara-api/ucm/pkgmgr/"

opts=("UCM_VAR_DIR=/var/lib/apd_ucm" \
    "CMAKE_INSTALL_PREFIX=$OECORE_TARGET_SYSROOT/usr/" \
    "ARA_ENABLE_DEBUG=ON" \
    "ARA_RUN_TESTS=ON" \
    "ARA_TEST_ARGS=\"--gtest_color=yes\"" \
    )

do_cmake ${srcDir} opts
